package message;


import static org.junit.Assert.*;

import org.junit.Test;


public class AbstractMessageTest {
	@Test
	public void smokeTest() {
		Note note = new Note("Roger", "Hung", "Hello world!");
		FriendRequest req = new FriendRequest("Roger", "Hung", "Hello world!");
		Challenge chal = new Challenge("Roger", "Hung", "Hello world!");
		
		abstractMessageTest(note);
		abstractMessageTest(req);
		abstractMessageTest(chal);
	}
	
	public void abstractMessageTest(AbstractMessage message) {
		assertEquals("Roger", message.getFromUser());
		assertEquals("Hung", message.getToUser());
		assertEquals("Hello world!", message.getMessage());
	}
}
